PWD := $(shell pwd)
name ?= pwm
obj-m := $(name).o
ARCH ?= arm


ifeq ($(ARCH),arm)
  KERNEDIR := /home/ubuntu/linux-5.10.61
endif

ifeq ($(ARCH),x86)
  KERNEDIR := /lib/modules/$(shell uname -r)/build
endif


all:
	
	make -C $(KERNEDIR) M=$(PWD) modules

clean:
	make -C $(KERNEDIR) M=$(PWD) clean


